none
SQL Server 2008 - how to convert directory to a URL RRS feed

  • Question

  • I am using SQL Server 2008 Enterprise. 

    1)  What would be the URL for a file named "test.asp" that is stored in this directory - "C:/Program Files/Microsoft SQL Server/MSSQL10.MSSQLSERVER/MSSQL/test.asp".  Assume the servername is "ServerJoe".  I have tried "http://ServerJoe/MSSQL/test.asp" and many other combinations without success (I get "HTTP request error", "Server.Error.RequestError: [IOErrorEvent type="ioError" bubbles=false cancelable=false eventPhase=2 text="Error #2032: Stream Error. URL: http://JWHPC/Reports/Pages/fas_mssql_connector.asp?irand=0.5500319339334965"]".  (Noticed I also tried storing the asp file in /Reports.)

    2) What is the root directory for SQL Server 2008?

    3) When asked for "userid" is it   domain\userid   or just   userid?

    4) In which directory should the crossdomain.xml file be stored?

    Thanks much.
    Thursday, January 20, 2011 3:24 AM

Answers

  • I'm sorry, but it seems like the documentation you extract text from was written by someone with very little knowledge about SQL Server and usage of SQL Server terminology. Things like " url to the ASP file you placed on your MS SQL webserver" and ”SQL Server root folder" has no meaning to us SQL Server people. The authors of that text seem to mix/confuse ASP and SQL Server, so you might have better luck if you talk to someone is good at that technology. Or, preferrably, as in a forum for that Adboe product, since you are most likely to find somebody hos have done that same thing in such a forum.


    Tibor Karaszi, SQL Server MVP | web | blog
    Thursday, January 20, 2011 4:55 PM
    Moderator
  • OK - I tried to take the quick and dirty way of accessing SQL Server 2008 databases from a Flex 4 application.  I guess that was not such a good idea. 

    Please refer me to a better way of using SQL Server 2008 databases in a Flex 4 application.  Is there a "best" book or online tutorial?  I have looked and there are many hits - just looking for a suggestion from someone who knows this area the best.

    Thanks!

    Flex or Microsoft Silverlilght is a pure client side technology so It cannot connect to SQL Server directly. You will  have to create web service that can access your data from SQL server and consume that web service in Flex.

    We currenty have a Flex Upload Control on one of our website, that retrieves data from SQL Server. It uses a web service created using WCF (windows communication foundation) to access SQL Server database.

    Connecting Adobe Flex to SQL Server -  http://codeexpander.blogspot.com/2009/10/connecting-flex-to-sql-server.html

    Thursday, January 20, 2011 7:34 PM

All replies

  • Hello,

    What are you trying to perform? You talk about a SQL Server, that's not a web server, you can't access files of it over a http address.


    Olaf Helper ----------- * cogito ergo sum * errare humanum est * quote erat demonstrandum * Wenn ich denke, ist das ein Fehler und das beweise ich täglich http://olafhelper.over-blog.de
    Thursday, January 20, 2011 7:37 AM
    Moderator
  • Thanks for the response.  I am trying to use "Adobe Flex Connector for MS SQL Server - ASP " (here is the link to the product: http://www.flexappsstore.com/index.php?route=product/product&product_id=65 ) to connect Flex 4 (Flash Builder 4) to an SQL Server Database.  In the documentation for the product it states:<!-- [if gte mso 10]> <mce:style>

    “You will need to copy the fas_mssql_connector.asp file to somewhere on your web server that will be accessible to your flex application and the MS SQL database” and then  “Enter the url to the ASP file you placed on your MS SQL webserver ”.  They also talk about the”SQL Server root folder” (which I am not sure which is the root folder).  Is there a way to attach a PDF file so I can attach the documentation?  If not here is a synopsis of the documentation:

    How to setup a New Project (#s 4 and  5b are the ones I am having trouble with )
    1. Import the Zip archive into a new Flex Builder 3 Project – This is the Demo project and tutorial with examples
    2. Create a Blank project in Flex Builder
    3. Copy the following file to your new project from the Demo project:  a. ActionScript/fas_MSsql_clean.as  source folder of your new project
    4. Copy the ASP file (fas_mssql_connector.asp) in the ASP Server File folder to your Web Server running both IIS that can connect to the MS SQL Server database.
    5 . Edit fas_MSsql_Clean.as:
       a. mssql_db = Enter the name of the MS SQL database you wish to connect to
       b . mssql_url = Enter the URL to the fas_mssql_connector.asp file on your web server
    6. Edit fas_mssql_connector.asp
       a. Enter your ms sql host, username and password
       b. By default, the port is set to 1433, you may change this if necessary.
    7. In your MXML application file reference the fas_MSsql_Clean.as file.
       a. Example:  i. <mx:Script source="ActionScript/fas_MSsql_Clean.as"/>
    8. Create a new ActionScript File for your SQL Functions

     

    General Usage : (these I am OK with - just listed here for semi-completeness)
    1. Create a function that will be called by an event (Button Click, Event Listner…)
    2. Use the mssqlQuery method to get data from the database:
       a. Syntax: mssqlQuery(“sql string”, “unique query token”);
       b. Example: mssqlQuery(“Select * from users”,”getUsers”);
    3. Add a case in the fas_MSsql_Clean.as file in the main switch in the mssqlResult function to catch the token:

       case “getUsers”:
       //Assign results to a Datagrid
       dgUsers.dataprovider = event.result.results.record;
       break;


    4. The data will be available to you in the event.result object.
    5. Add a case/break statement in the main switch of the function mssqlResult
       a. Syntax case “unique query token”:
        myControl.dataprovider = event.result.results.record;
        break;

    6. See demo project for how the event.result is assigned to various controls.

    Thank again for any help/direction/pointers to documentation!

     

    Thursday, January 20, 2011 4:09 PM
  • in the previous reply please ignore "<!-- [if gte mso 10]> <mce:style>" - not sure how it got there... sorry.
    Thursday, January 20, 2011 4:13 PM
  • I'm sorry, but it seems like the documentation you extract text from was written by someone with very little knowledge about SQL Server and usage of SQL Server terminology. Things like " url to the ASP file you placed on your MS SQL webserver" and ”SQL Server root folder" has no meaning to us SQL Server people. The authors of that text seem to mix/confuse ASP and SQL Server, so you might have better luck if you talk to someone is good at that technology. Or, preferrably, as in a forum for that Adboe product, since you are most likely to find somebody hos have done that same thing in such a forum.


    Tibor Karaszi, SQL Server MVP | web | blog
    Thursday, January 20, 2011 4:55 PM
    Moderator
  • OK - I tried to take the quick and dirty way of accessing SQL Server 2008 databases from a Flex 4 application.  I guess that was not such a good idea. 

    Please refer me to a better way of using SQL Server 2008 databases in a Flex 4 application.  Is there a "best" book or online tutorial?  I have looked and there are many hits - just looking for a suggestion from someone who knows this area the best.

    Thanks!

    Thursday, January 20, 2011 7:13 PM
  • OK - I tried to take the quick and dirty way of accessing SQL Server 2008 databases from a Flex 4 application.  I guess that was not such a good idea. 

    Please refer me to a better way of using SQL Server 2008 databases in a Flex 4 application.  Is there a "best" book or online tutorial?  I have looked and there are many hits - just looking for a suggestion from someone who knows this area the best.

    Thanks!

    Flex or Microsoft Silverlilght is a pure client side technology so It cannot connect to SQL Server directly. You will  have to create web service that can access your data from SQL server and consume that web service in Flex.

    We currenty have a Flex Upload Control on one of our website, that retrieves data from SQL Server. It uses a web service created using WCF (windows communication foundation) to access SQL Server database.

    Connecting Adobe Flex to SQL Server -  http://codeexpander.blogspot.com/2009/10/connecting-flex-to-sql-server.html

    Thursday, January 20, 2011 7:34 PM
  • Thanks very much for your quick responses - much appreciated!
    Thursday, January 20, 2011 9:22 PM