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 TouchToneTommy on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Recent content by Naranek

  1. Naranek

    Dynamic sql in functions

    The problem is that it is almost 200 tables, and they are stored in a TableInfo table. I must use a 3rd party tool to present the values, but due to limitations in that software I must make all the functions in the database itself. The software has no way of doing this. It is not a programming...
  2. Naranek

    Dynamic sql in functions

    Hello Experts, I am trying to make a function to get the rowcount of a table, where the table name is the argument into the function. SELECT @SQLSENT = 'SELECT COUNT(*) FROM ' + @AS_TABLENAME + ';' EXECUTE sp_executesql @SQLSENT, N'@LL_COUNT INTEGER OUTPUT', @LL_COUNT OUTPUT RETURN...
  3. Naranek

    Dynamic tablename in function

    Yes, thanks. Quite easy once you know it. :)
  4. Naranek

    Dynamic tablename in function

    Hello Experts, I am trying to pass a tablename into a function and return the rowcount for the given table. I made it Sybase using a string variable and a cursor. Is there a simular way to build a string, then use the string as the SQL statment for a cursor? my_sql := 'SELECT COUNT(*) FROM '...

Part and Inventory Search

Back
Top