Forum Replies Created

Viewing 15 posts - 61 through 75 (of 119 total)

  • RE: Complex Stored Procedure

    Hi Malesh

    Got the following errors:-

    Msg 102, Level 15, State 1, Procedure sp_getpageidsforedb, Line 21

    Incorrect syntax near ')'.

    Msg 137, Level 15, State 2, Line 4

    Must declare the scalar variable "@projectid".

    Msg 208,...

  • RE: Error in Stored Procedure

    Now its working fine and returning the correct data, since before, it was filtering with 2 HamTeamsID parameters

    So for example it was trying to get HamTeamsID 1 and HamTeamsID 2...

  • RE: Error in Stored Procedure

    Hi Kenneth

    I found my error.

    I was repeating the same variable @HamTeamsID, when it was supposed to be @PosID!

    so

    where (HS_Players.fk_hamTeamID = @HamTeamsID or @HamTeamsID <> 0)

    and (HS_Players.playerName = @Name or @Name...

  • RE: Error in Stored Procedure

    Hi Kenneth

    I changed everything as you told me so the stored proc looks like this now

    ALTER PROCEDURE dbo.HS_Players_GetPlayers_BY_Criteria

    (

    @HamTeamsIDint,

    @Namenvarchar(100),

    @Surname ...

  • RE: Error in Stored Procedure

    Hi Kenneth

    What I am trying to do is this.

    I am passing 4 parameters in, and if there is any value, then the where clause is supposed to do the where...

  • RE: Error in Stored Procedure

    Hi Kenneth

    I changed the order, and now its not returning anything

    I am entering 1 as HamTeamID and 2 as PosID, and '0' for Name and Surname.

    Its supposed to return 2...

  • RE: INSERT_UPDATE Stored Proc

    Thanks Guys

    It works

  • RE: INSERT_UPDATE Stored Proc

    Hi ijaz

    I tried it like this:-

    /*

    *********************************************************************************************************************

    ******This stored procedure inserts a header according to its ID.

    ******Created :- Johann Montfort

    ******Date:- 20/10/2006

    *********************************************************************************************************************

    */

    ALTER Procedure [dbo].[INSERT_UPDATE_Header]

    (

    @admin_menu_id int,

    @admin_submenu_id int,

    @header_file varchar(150),

    @header_alt varchar(150),

    ...

  • RE: inserting in 2 tables simultaneously

    Hi Will

    Thanks for your reply.

    I will keep on using the Identity fields as you suggested, since its much easier to let SQL Server handle the dirty work for me.

    Thanks again

    Johann

  • RE: inserting in 2 tables simultaneously

    Hi Journey man,

    To tell you the truth I have never used triggers, I am new in SQL Server.

    Another thing, today I had a chat with a fellow colleague, and he...

  • RE: insert simultaneously in 2 tables

    hi Sreejith Sreedharan

    I tried your stored procedure finally, since I had some problems with my laptop, however I got the following errors:-

    in this piece of code:-

    --Detail - Update Existing

    Update...

  • RE: insert simultaneously in 2 tables

    Wow

    Thanks a lot guys, its nice to learn new things!

    I did not know that the Update will be ignored if the data does not match!

    Another question, is it best to...

  • RE: insert simultaneously in 2 tables

    Hi Sreejith,

    I tried your code and got the following errors:-

    Msg 156, Level 15, State 1, Procedure INSERT_Header, Line 24

    Incorrect syntax near the keyword 'where'.

    Msg 156, Level 15, State 1, Procedure...

  • RE: Error when trying to restore a database on SQL Server 2005

    Hi eric

    I tried this code:-

    RESTORE FILELISTONLY

    FROM DISK = 'C:\INSERO\VNE Logistics_backup_200607271528.bak'

    and still gave me the error:-

    Msg 3205, Level 16, State 2, Line 1

    Too many backup devices specified for backup or restore;...

  • RE: Error when trying to restore a database on SQL Server 2005

    Hi eric

    I already saw that article you mentioned but no help.

    Is it possible to explain to me where in SQL Server 2005 should I do the Query, and where I...

Viewing 15 posts - 61 through 75 (of 119 total)