Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations SkipVought on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Search results for query: *

  • Users: UGrad
  • Order by date
  1. UGrad

    EVAL() in .NET?

    I found the solution. Set a reference in your app to "Microsoft Script Control 1.0" It is under the COM tab in references. Then the code is really simple. Dim SC As New MSScriptControl.ScriptControl SC.Language = "VBSCRIPT" Label1.text = Convert.ToString(SC.Eval(TextBox1.Text))...
  2. UGrad

    EVAL() in .NET?

    Thanks, I will take a look.
  3. UGrad

    EVAL() in .NET?

    The reason I asked is because I want to use eval() to evaluate a string. This string is an input from user. Basically, I have a text box for user to type in a string. Then I evaluate the text in the box. For example, user can type in: datediff("d", now, "1/1/2006") or...
  4. UGrad

    EVAL() in .NET?

    Hi, I did some research on this, but I couldn't find any answer. In classic ASP, I can use eval() to evaluate a string. For example, if I do eval(len("test")>5), it will return false. Or if I do eval(len("test") > 1 and len("test") < 5), it will return true. Is there a function in...
  5. UGrad

    Call stored procedure on other server

    Hi, I have two SQL 2000 servers, A and B. On server A, there is a stored procedure C. On server B, there is a stored procedure D. Is it possible to call D inside C??
  6. UGrad

    Is there an easier way to create a form for editing a database table?

    Yeah. 100 fields is a bit much. I use the table to store contact info. For exmaple: first name, last name, business phone #, home phone #, and .... Not all fields are required.
  7. UGrad

    Is there an easier way to create a form for editing a database table?

    Hi, I have a SQL database table with around 100 fields. I created a search page for user to search the table. Then another page to display the search result. User can click on each record and go to another page to do the editing. My question is for the editing page, I have to manually...
  8. UGrad

    How to get the record ID after insert?

    ExecuteScalar? Cool.. That's a new term for me. I will do some research on in. Thanks for all the helps.
  9. UGrad

    How to get the record ID after insert?

    Will this work if I change my query string to this? "insert into tbl_User (name) values ('User1');select @@identity;
  10. UGrad

    How to get the record ID after insert?

    Hi, I am new in ASP.NET. Is there a way to get the identity ID from a SQL table after insert a record? I have those 3 lines of code I am using to insert user into a table, and this table has a column called ID as its identity column. Dim comm As New Odbc.OdbcCommand("insert into tbl_User...
  11. UGrad

    Need some help to write a query

    Problem solved: 1. Create following founction. CREATE FUNCTION GetPatID (@DocID int) RETURNS varchar(500) AS BEGIN declare @Crsvar cursor declare @PatID int declare @returnstr varchar(500) set @returnstr = '' SET @Crsvar = Cursor for SELECT PatID FROM Table2 where DocID = @DocID OPEN...
  12. UGrad

    Need some help to write a query

    If Access it's possible to create a simple crosstab query like this: TRANSFORM Min(Table2.PatID) AS MinOfAMOUNT SELECT Table2.DocID FROM Table2 GROUP BY Table2.DocID PIVOT [PatID]; I have a table called Table2, with 2 columns DocID and PatID: ID DocID PatID 1 2 11 2 1 22 3 2 33 4 2 44 5 1 44...
  13. UGrad

    Need some help to write a query

    Thank you very much for posting that link. I already have a stored procedure very similar to the one you posted. But what I want is just a simple query. I guess there is no way to make it. Thanks..
  14. UGrad

    Need some help to write a query

    I am trying to write a query to format my data. But if there is no easy way to do it, I will write a stored procedure and run it every hour to get the result I want. Hopefully, there is an easy way.. =)
  15. UGrad

    Need some help to write a query

    All I want is to create a summary view of doctors with their patient IDs. I guess I am still used to the crosstab function in Access and don't know why SQL doesn't have this neat feature. Anyway, in the worst case, I can write a stored procedure to create this table. Thanks for your reply.
  16. UGrad

    Need some help to write a query

    Hi, Can anyone help me to figure out how to write this view in SQL 2000? I have this table: DoctorID PatientID 104 111 104 222 103 354 104 265 103 589 Is there an easy way to write a view based on this table and the view looks like...
  17. UGrad

    Need some help to write a simple query

    Thanks, PHV. I wrote my query in SQL and didn't know Access doesn't support count(distinct).
  18. UGrad

    Need some help to write a simple query

    So For EmployeeID 1, he has 2 cars. For EmployeeID 6, he has 1 car.
  19. UGrad

    Need some help to write a simple query

    CarID is car identifier.
  20. UGrad

    Need some help to write a simple query

    Hi, I am trying to find a way to write a query. I think it's easy, but I just don't know how to do it. I have a table called "table1" looks like this: EmployeeID CarID ------------------- 1 1 2 2 3 3 4 4 5 5 1...

Part and Inventory Search

Back
Top