Computer Problems? Computing.Net has over 1,000,000 posts about all things technology related! Over 90% answered within 24 hours! Click here to start participating now! Also, be sure to check out the New User Guide.
Help in SQL
Name: jds Date: April 15, 2004 at 11:04:30 Pacific OS: windows2000 CPU/Ram: petium II/ram 256
Comment:
Hi, I am new in SQL. I need someone's help. I have table which contains: userID, group 123 1 234 2 345 1 456 3 ... I want to write a query which can base on group write into different files like group 1 to file1, group2 to file2 How can I get this done. Any help would be appreciated
If the number of groups are not that many, you can run the query for each group and save it and make the changes for the next group, run the query and save it and so on.
Farnoush Hakakian
0
Response Number 2
Name: jds Date: April 15, 2004 at 12:46:43 Pacific
Reply:
Thanks for your response Farnoush. The thing is this is the first step. I need base on the file created by this query do some other stuff after. So I need to make it automated. besides, I got many groups can't do it manually.
0
Response Number 3
Name: gpp Date: April 15, 2004 at 13:53:02 Pacific
Reply:
You probably need to write a script to do this then. You can loop thru the result set and based on the group, write to a certain file.
0
Response Number 4
Name: jds Date: April 15, 2004 at 13:57:46 Pacific
Reply:
You mean sql script or DOS script? could you show me how?.Thx
0
Response Number 5
Name: gpp Date: April 15, 2004 at 14:23:25 Pacific
Reply:
I was thinking more on the lines of perl.. but I'll have to post something for you tomorrow, I need to get going.
0
Response Number 6
Name: jds Date: April 19, 2004 at 14:22:21 Pacific
Reply:
Perl would also be good as I am learning that too. Thanks
Summary: Dear Friends, I need one help in SQL Server. I have 2 tables R1 and R2 and both of them have 2 fields rollno and name. I want to select all the records from both the tables and sort the resultant reco...
Summary: I have a query to run against a db with millions and millions of entries. I'd like to test the query before running it against the entire db. Is there a way to run the query against only the first 10...
Summary: Hi everyone, I would like to ask a question about SQL.. Im using SQL*PLus Oracle... I have a database with 50 records in it( i.e. 50 rows of information ). One of the fields is price I would like to s...