CakePHP SQL Log - How to check the SQL Logs from previous requests? - sql

I'm trying to learn CakePHP using the Bookmark tutorial.
When I use the "baked" application forms to create or edit new Entities, they typically redirect to the index action following successful submission. At this point, the Sql Log in the Debug Kit only shows the SQL used to generate the index listing, not the Sql that was used to do the update.
Is there an easy way to see the Sql that was used for creates/updates in the Debug Kit Sql Log either before or after submission?

Debug Kit stores a history of requests, which you can inspect at any point.
Head over to the History tab
Click on the last POST/PUT request
Head back to the Sql Log tab
You should now see the queries from the previous request.
See also Cookbook > DebugKit > Using the History Panel

Related

How do I see the source tables that Infor XA Power-Link is using to create the current view?

Through Infor XA Power-Link, I have access to a sales history view with things like quantity, price, item number, etc.
Using System i Navigator, I would like to be able to run a SQL script that produces a similar table, but customized to my liking.
However, I'm having trouble locating the tables involved in producing the Power-Link view. Is there a way to check the source using Power-Link so that I can get the table names?
Sure is! You need to use the SQL Monitor. Start the business object and go to Help then About Infor. The about screen will appear. Hit Control-D to start the SQL Monitor. You should see 3 columns: Start, Duration and SQL. Refresh the view and see the SQL Monitor will populate. Right-click and copy the entry that has 'SQL SW executeQuery' entry and paste into your favorite SQL editor. This will be the exact SQL select statement used by PowerLink. Modify to your needs.
Let me know if you need anything else.
Matt
Note: You can prevent users from accessing any of the Diagnostic tools which includes the SQL monitor. This is done via security task DSPDGNINF. It's located under the CAS application > Client System Preferences security area.
Load menu AMZM38 - CAS Security Maintenance
Select Option 1 Area and task authorizations
Select CAS as the application
Use Option 2 Change on Client System Preferences security area
Use Option 11 Authorize users to configure who should have access and who should not (revoke)
F12 to go back one screen
Lock task DSPDGNINF
Please note, security is not active until the task is locked. Also, to test, one must use a new Power-Link session as security is cached.

Azure SQL Create Database Status hangs

I am trying to create a SQL Azure db (I've done this dozens of times via the portal) but the process hangs on the Create Status and a half hour later it finally quits and deletes the database.
Are their any logs I can look at to see what is going on?
From the Azure portal, click on your username in the top right and select "Switch to New Portal".
On the left hand side of the new portal is a Notification tile. Click the notification tile, which expands a blade on the right hand side. Within that blade is a link which states "See all Audit Logs". Click that link to see the basic logs giving more detailed information regarding processes that you have attempted from the admin portal.
Clicking on each log entry expands into more details on individual components of each action. See imagery below for when I created a SQL Azure Elastic DB Pool.
I have had databases hang in a COPYING state on multiple occasions and each time have had to open a case with Microsoft to effect resolution.

MS Search Server Express Throws an Exception

I installed MS Search Server Express and crawl some Ektron documents and those documents are successfully indexed.
Next when I tried to search I got the following error.
I also installed some hot-fixes as suggested by several websites. However, this error still throws, when I try to search my documents.
Do you have any idea?
I had this happen and ended up going to the search manager site - something like yourhost:1234 or some other port. Once there, you navigate to the search service configuration screen and you'll notice the database connections, etc at the bottom. An Ektron support person had me create a new configuration and delete the old one. This actually drops the tables in SQLServer and creates new tables with long numbers at the end of the table names. After doing this, it all started working again. You can always drop your Sharepoint* tables, register your site again and do a full crawl to start over.

Login Failed for user [sql server user]

I am new to SSRS and have deployed several reports. When I force windows authentication, everything works fine, but when I do this:
I am getting this error:
An error has occurred during report processing. (rsProcessingAborted)
Query execution failed for dataset 'DataSet1'.
(rsErrorExecutingCommand) Login failed for user 'DWH_Reporting_User'.
I've configured the DWH_Reporting_User like this:
here are the details on DWH_Reporting_User for the ReportServer database:
here is the security on the server:
when i try to set security for that specific folder:
i am getting this error msg:
is there something obviously wrong with the way I've configured things?
The answer to this question was a series of comments. I went ahead and put it in the chat as well as an answer.
Go to the security of the server not the database and map the user to that database.
Can you recycle the application pool on the server where reporting services is running? Or reboot the IIS server if possible.
Another thing that comes to mind, when you launch this report it goes into the report server "Portal". Does this user have access to the actual report to view it? Click the details section of this "Portal" and assign this user as a content manager role.
DWH_REPORTING_USER is this an admin account on your domain?
Local admin on the server, so did you grant \COMPUTER_NAME\DWH_Reporting_User rights as a content manager in the roles section? Why dont you use a domain admin account?
So how do you access the actual report - that is your issue.
Do me a favor aprem, write up a stored procedure or sql query in the first tab of reporting services and run it using that user. Meaning in the shared data source it should be using this user DWH_Reporting_user. Test the connection then write a small sql statement to retrieve some data. Run the SQL script from within RS do you see any data?
#Aprem look at the three tabs at the top of rs, its the first tab to define datasets, this is where you can create an SQL query (and run it using the red exclamation mark). – JonH 20 mins ago
i defined a new dataset as "select top 1000 * from mytable", i rebuilt the project, deployed it, and now what do id o? – Артём Царионов 16 mins ago
In the "Shared Datasets" you have a dataset right? Double click on it and go to "Query Designer" it is a button on this form. Click on it and "Execute" the query (red exclamation mark). You dont need to deploy it right now, just do it on a test machine.ago
You specify the user in the datasource section "Shared Data Sources", that account is the account being used to "pull" the data. You really need to experiement with RS some more or read some material on it. This is as basic as it gets.
*Ok aprem do you understand your issue now, the user you are using to get the data has no issues, in addition, it is functioning correctly. Now you have to view the report. To view the report is to view the webpage, and to view a web page means you need to either use "Anon" access or windows authentication. So you need a domain or local WINDOWS account to view the report. This account needs to be setup on the RS portal as a content manager role. *
You are dealing with two beasts, one is the database (db server) and one is IIS (web server) each serve a specific purpose. The database serves to allow you to pull data while the web server hosts the pages.
The reportserver database is very important, it keeps a listing of all your reports and the meta data associated with your reports in the database. It also stores job ids and subscriptions associated with your reports. Basically it is the backend database for all reporting services stuff like reports, datasets, and datasources. Think of it this way when you create a new "Report Project" you are allowed to create reports, datasets, and datasources. Without the reportserver database how would the system remember your datasets, datasources, and report names? It is the heart of rs.
your data set is not used to connect to the reporting services databse, it is used to connect to the database you are getting the data to display on your report.
Does that user exist on the database the report is accessing?

Pulling Data From an SQL Database in HTML 5

I am trying to develop a BlackBerry application that will show data from an SQL Database from a server. I was researching the new HTML 5 option for blackberry (WebWorks) and noticed that it apparently cannot connect to any server data by itself. Some links state that I would need javascript coding to obtain it. I looked into the option of PhoneGap (link here: http://phonegap.com/) and decided I'd try using HTML 5 to produce the application. I have never touched SQL databases before and I am wondering how I would connect the two; meaning how do you pull data from the server given that you are working with HTML5?
I have looked at:
Where is data stored when using an HTML 5 Web SQL Database
Process for pulling data from a sql database
among others but I am still unsure as to what to do. I would be looking to "view" the data from the server and display it on the app. It would be something of the sort:
- HomeScreen: What data would you like to view?:
- Dropdown list of categories (from the database)
- Selecting Entry in dropdown leads to available information (from the database)
Any help would be appreciated, and of course thanks in advance.
the new (and pretty awesome) features of HTML5 is happening in the browser on the client side. What you will need is a back-end on the server side doing some magic. It is true that browsers now have databases but these are located on the phone, computer etc and as I understand your question you want these data to communicate with data on your server. To move data across the web you will need to perform HTTP-requests which can easily be done through javascript and ajax. Look a bit into these technologies and make a little server-side script that gathers data from the database and send it in a structured format to the phone (JSON, XML), then make a script in javascript on the client-side that parse these data and utilise them.
Good luck!