Friday, March 30, 2012
IVR to Database to Web
I am about to begin a project that will be implemented in a local company. It involves using an IVR(interactive voice response) to collect information with regards a customer satisfaction survey. The results are then to be presented on the web. Thus I have an IVR connected to a database which is connected to the web. The results are to be presented in stats and graphs on the web.
I was originally going to use an Oracle database however it has worked out that it is not feesable to use Oracle for such a small application. I am now looking at SQL server. However, I have never dealt with it before. I have extensive knowledge of SQL. What I need to know is SQL server suitable to use when it comes to connecting to a web application, querying the data to show graphs and stats and is it easy to learn for a person who has extensive knowledge of databases? Id appreciate your knowledge and advice on this topicHowdy,
Greetings from sunny Surrey in the UK!!
Well the short answer is - yes - if you are willing to take the time to learn SQLs eccentricities.
Regards size , we have 5 MB databases running ( some with web app links ) so small isnt an issue.
SQL Server is pretty easy to learn, and if you are just quering the database or writing data into it from a web app, it should all be straight forward. Mind you...how long is a bit of string?
Do you have a DBA to set up the server or are you it?
Cheers,
SGsql
Wednesday, March 7, 2012
Issue with Dynamic SQL stored procedure and SSIS OLE DB Data Reader
We are writing SSIS packages to pull data from MSO’s through a stored procedure and drop the output into the pipeline to store it on our local database.
Here is an example of a very simple data flow task that executes the following query in step 1
EXEC GetCustomerData @.SELECT = 'OrganizationID', @.FROM = 'Organization',@.WHERE = 'StateOrProvinceCode = ''WA'''
This command is stored in a variable called SQLOrgCommand.
When I open the task and click on Columns I do not see any columns returned
This allows me to conclude that the metadata needed from the GetCustomerData is not understood by SSIS because the SP uses dynamic sql.
While profiling we realized that it executed the following SQL:
SET FMTONLY ON
to get the metadata. However when we ran the sp with FMTONLY ON we recieved the following errors
Msg 536, Level 16, State 5, Procedure sp_GetData, Line 100
Invalid length parameter passed to the SUBSTRING function.
Msg 536, Level 16, State 2, Procedure sp_GetData, Line 101
Invalid length parameter passed to the RIGHT function.
Msg 536, Level 16, State 5, Procedure sp_GetData, Line 116
Invalid length parameter passed to the SUBSTRING function.
Msg 536, Level 16, State 2, Procedure sp_GetData, Line 117
Invalid length parameter passed to the RIGHT function.
Msg 536, Level 16, State 5, Procedure sp_GetData, Line 187
Invalid length parameter passed to the SUBSTRING function.
The same stored procedure executed without FMTONLY OFF generates the proper output.
Is this a known bug in SQL Server? If so is there a patch that we can install.
Can you post an example of the stored proc you're using? I created a dynamic sql sproc and it seems to work just fine.