Reasons for Empty Dataset - google-bigquery

Can you please explain the possible reasons that I'm unable to view the schema of a .csv dataset that I'm attempting to import (from a local file) into bq. The table name and icon appear in the left pane, but when I click on the table icon, I don't see a schema similar to the ones for the sample datasets. As far as I can tell, I'm correctly inputting the schema for each field name.

While the table is importing, it may show up in the left hand pane without a schema. If the import fails, then you'll never get a real table to be populated there. If you click on the job history link on the upper right side of the page, you should see your load job and you can see whether it succeeded or failed. If it failed, you should be able to click on it and see the errors from the job.

Related

Unexpected error Tracking number: c904462681469709

been trying to create a table in sandbox and i'm getting an "Unexpected error
Tracking number: c904462681469709". sometimes the table gets created, sometimes it doesn't.
any wizards that can help me with this?
cheers,
I ran into the same issue today, I do not know what causes the error, but I found that BigQuery has loaded my table. The steps I used are as follows:
Click the three dot drop down to create the table.
Fill out the source, destination, schema for the table.
After clicking 'create table' receive the error and close out the error window.
Close out of the create table window.
Refresh your BigQuery page.
Check the dataset you created the table under and it should be there.
I hope this method works for you as it did for me!
That happened to me too. So strange but yes I did the same thing Devin did. Took me forever trying to figure it out but it is what it is. Just refresh and keep going.

Are some bigquery public datasets no longer available?

When using the BigQuery GUI interface, I'm no longer able to browse the bigquery-public-data.stackoverflow dataset. It doesn't show up in the Public Datasets dropdown, where I was previously able to view the schema. On the other hand, I am able to query the table.
Have some public datasets been removed from the GUI?
The original issue was due to a bug that caused Pinned Projects to be hidden. It has since been fixed.
Regarding static_rtti's request to use the pushshift reddit dataset:
I see two ways to accomplish this:
(1) Using the original UI:
From the Cloud Console, click "Go to classic UI".
Click the little arrow next to your project name on the upper left.
"Switch to Project" > "Display Project"
Enter "pushshift" (Display Project in Navigation Panel) and submit.
You should now see a new pushshift project w/ the reddit dataset in your navigation panel.
(2) Using the new UI:
I don't see an obvious way to add a project if you aren't a member, but you can use the same trick that the public dataset browser employs. Replace YOURPROJECT with your project name in the URL below and navigate. This will pin the specified dataset for later access.
https://console.cloud.google.com/bigquery?p=pushshift&d=rt_reddit&page=dataset&project=YOURPROJECT&folder&organizationId
Hope that helps!
Use this URL in your browser:
https://console.cloud.google.com/marketplace/partners/bigquery-public-data
Then you can click on the "view all" button and look for the the ones you need.
This is the link to the bigquery-public-data.stackoverflow, click on the view dataset to use it in the WebUI.
You can review this document on accessing the public dataset.

How to recover deleted View in BigQuery?

I have deleted a view in bigquery. I came to know there is an option to restore deleted tables based on table snapshot decorators. Is there any way to retrieve deleted bigquery views?
There is a way to get it back. You need to search for insertion logs rolled at a time of creating your view. This logs can be seen from stackdriver logging. Here are the steps :
Go to GCP console
Click on stackdriver logging
Click on arrow present in search text box and select "Convert to advance filter"
Now remove everything and paste below query in it. Don't forget to put your view name in a query.
resource.type="bigquery_resource"
protoPayload.methodName="tableservice.insert"
protoPayload.serviceData.tableInsertRequest.resource.tableName.tableId="Your_view_name"
You will get record of your view creation, Now click on Expand all and go to view section. There you can find a query used at a time of view creation.
Just paste that query in bigquery and click on save view.
Alternatively, if you want to search for updates to the view to recover a specific version you can use the following filter:
resource.type="bigquery_resource"
protoPayload.serviceData.tableUpdateRequest.resource.tableName.datasetId="<dataset_id>"
protoPayload.resourceName="projects/<project_id>/datasets/<dataset_id>/tables/<table_or_view_id>"
I hope this helps you get back your BQ view.

Adding New Query to Database

I am trying to follow this video and get stuck at 2:43 where he right clicks the database in server explorer and clicks 'New Query', once I do that it brings up the right sql file tab, but in the dropdown box where it has all the available databases, the one I created is not there, it only contains 'master, model, msdb, tempdb' I've tried searching for an answer and cannot find one.

Microsoft SQL Server not letting me open .bak

I am taking a class and our instructor gave us a file to download called cs.bak and its supposed to be formatted for the version of SQL we are using. So I downloaded the one for Microsoft SQL Server.
Well I tried to do the restore but when I get to the part that I choose device and locate the file cs.bak it loads and now I am suppose to be able to choose destination. Well after I choose destination I do not have the OK button to go through with the restore.
On these instructions http://www.katieandemil.com/sql-server-2012-restore-database-backup-file
If you count the window screens. I can only get as far as the 6th screen.
I am suppose to do this, "Some questions will ask you to write out query results from a database. In order to answer these questions you will need to have the example database available to you."
Well I can't open it to do this. Any help would appreciated. Thank you.
Check this:
This checkbox might be unchecked - and then the [OK] button remains disabled...
This seems to be a Windows Layout issue. To resolve this, reset the SSMS Window Layout by selecting from the main menu Window -> Reset Windows Layout.