Search results

  1. P

    Complex subquery?

    Nice tip, i'll try to look into that when i get back to work on monday. I do not have to much experience with self join queries. I've tried to search around a little bit but haven't found any site with good example.. Any tip of sites with example would be appreciated. Thanks Paal
  2. P

    Complex subquery?

    I've checked the particular table in deep and there 4 level depth. I guess that would make it even harder. Paal
  3. P

    Complex subquery?

    Nice work, but then you need to now every name of project, subproject, which i don't know. Project, subproject was just two example. I could get all project subproj and put it into the query, but it would then be huge and the need of query update every time a new project is added is not what i...
  4. P

    Complex subquery?

    I've been asked to create a query from a table in a database. I haven't design the database and wouldn't create it like this. Anyway i'm a little stuck and could need some help. Table contain several fields but only three of them is important. If i do this: select * from project i get this...
  5. P

    query challenge

    I got solution from another forum and i was close. Solution is: select * from itemtype left join freighttype on freighttype.itemtypeid = itemtype.itemtypeid and freighttype.freightid=1
  6. P

    query challenge

    I understand, i'm not sure on how to but them together. But so far it's something like this: First to select all available items : select * from ItemType Then select all which have freightID like 1 select ItemTypeID, NumberOf from freighttype where freightID=1 I'm unsure of how to combine...
  7. P

    query challenge

    So anyone who can give a hand? Paal
  8. P

    query challenge

    No i don't have a field called that. The two table i got have the following definition. TABLE FreightType ( FREIGHTID-------------------------INT NOT NULL, ITEMTYPEID------------------------INT NOT NULL, NUMBEROF-------------------------INT, FOREIGN KEY (FREIGHTID) REFERENCES...
  9. P

    query challenge

    Seems right but it seems like i forgot to mention something, If all types are registered on another FreightID i will only get the one with selected ID and NULL. That mean i won't get all item listed. What i'm trying to do is to get all item listed and if any of them on a particular FreightID...
  10. P

    query challenge

    agree, but i want to list for that particular id. This query is going to be used as listing thign which are registered and list the different types of item available so that the user can add them as well.
  11. P

    query challenge

    I've been working on this query which i can't seem to get right. I have two table ItemType (2 fields: ItemTypeID, Type). Then FreightType (3 fields: FreightTypeID, ItemTypeID, NumberOf). FreightTypeId is a unique freight which can containing several items Table ItemType ItemTypeID----Type...
  12. P

    query question?

    So it was just matter of grouping by all selected fields you wanted. Thanks Paal
  13. P

    query question?

    I have several tables which i want to get information from and i have a query with lots of inner join which works fine. But one of the table contain a field named numberOfItem which i want to sum and list with the others. Queries are like this: Query1: SELECT Freight.FREIGHTID...
  14. P

    Problem with report

    I've solved the problem, the solution for this problem is to change the grouping so instead of grouping of only lastname i grouped on bouth primary key, lastname and firstname. In order to get it asc. sort on lastname and firstname i put them before primary key field. My problem was that if two...
  15. P

    Problem with report

    Hi, I have a report which is based on a query. If i open the query i get all the data exactly as i want, but if i open the report it's seems like there some data which is lost. At least it's not printed on the report. This is a salary report what i get on the report are everything else except...
  16. P

    Error message : Query must have at least one destination field

    Hi, I have a query which suddenly get's empty and i get the following error: Query must have at least one destination field If i open the query in design mode everything is gone and the remain is Select; Anyone experienced this problem. It's occurs now and then related to export of data to...
  17. P

    Problem With export from Access

    I have a query like this: SELECT [Person].[Personnr], [Person].[Fornavn], [Person].[Etternavn], [Stillingsgruppe].[Navn], [Person].[Ansattdato], [Organisasjon].[Navn], [Person].[LonnsGID], [Person].[AvdID], [Avdeling].[Navn], [Person].[Eksamensaar], [Person].[Merknad] FROM Stillingsgruppe INNER...
  18. P

    Query get corrupt

    Hi, i have a problem with a query which get corrupt after use. Problem is like this. I'm exporting a query to excel format and everything works fine. But if i turn of the setting under startup options lik this: ChangeProperty "StartupShowDBWindow", DB_Boolean, False ChangeProperty...
  19. P

    Calculation problem in report

    Hi I have the following query: SELECT [Selskap].[Navn], '19'+Mid([Person].[Personnr],5,2) AS År, IIf(((Mid([Person].[Personnr],9,1)) Mod 2)=1,"","1") AS Kvinne, IIf(((Mid([Person].[Personnr],9,1)) Mod 2)=0,"","1") AS Menn FROM Selskap INNER JOIN (Avdeling INNER JOIN Person ON...
  20. P

    Problem with Listbox

    Hi, I have a listbox on a form which use a query to get information about person which is registered. Problem is that sometimes the listbox won't show everything in the query. If i open the query direct i get everything, but not in the list box. I've even tried to put a button on the forms...
Back
Top Bottom